# -*- coding: utf-8; mode: snippet -*-
# name: (trim string)
# key: trim
# contributor: Chen Bin <chenbin DOT sh AT gmail>
# --
(replace-regexp-in-string (rx (* (any " \t\n")) eos)
                          ""
                          $0)